namespace myclass {
  class Db {
    field: string[]
    constructor(field) {
      this.field = field
    }
  }

  class ProxyCreateSingleton {
    static instance = null;
    constructor() {
      const fields = ['createTime', "updateTime"]
      if (ProxyCreateSingleton.instance) {
        return ProxyCreateSingleton.instance
      }
      const db = new Db(fields)
      // db.connect()
      return ProxyCreateSingleton.instance = db;
    }
  }

  const obj = new ProxyCreateSingleton()
  const obj_1 = new ProxyCreateSingleton()


  // console.log(obj, obj_1, Object.is(obj, obj_1));



  class DataBase {
    fields: string[]
    pool: any
    constructor() {
      this.fields = ['createTime', "updateTime"]
    }
    connection() {

    }
    query() {

    }
    init() {
      this.pool = {
        name: 'zs',
        age: 100
      }
    }
  }

  class Classify extends DataBase {
    constructor(fields: string[]) {
      super()
      this.fields = [...this.fields, ...fields]
    }
  }

  class name {
    constructor(parameters) {

    }
  }

  const db = new DataBase()
  db.init()

  console.log(db);

  console.log(new Classify(['id']));



}